package org.dromara.mall.domain;

import org.dromara.common.mybatis.core.domain.BaseEntity;
import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.dromara.common.translation.annotation.Translation;
import org.dromara.common.translation.constant.TransConstant;

import java.io.Serial;

/**
 * 商品对象 ter_mall_product
 *
 * @author xch
 * @date 2025-06-27
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("ter_mall_product")
public class TerMallProduct extends BaseEntity {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     *
     */
    @TableId(value = "id")
    private Long id;

    /**
     * 分类ID
     */
    private Long categoryId;

    /**
     * 商品名称
     */
    private String name;

    /**
     * 价格
     */
    private Integer price;

    /**
     * 库存
     */
    private Integer stock;

    /**
     * 缩略图URL
     */
    private String thumbnail;

    /**
     * 详情图URL（JSON数组）
     */
    private String images;

    /**
     * 商品描述
     */
    private String description;

    /**
     * 销量
     */
    private Integer sales;

    /**
     * 状态(0=上架,1=下架)
     */
    private Integer status;

    /**
     * 是否热销
     */
    private Integer isHot;

    /**
     * 删除标识
     */
    @TableLogic
    private String delFlag;

    /**
     * 轮播图
     */
    private String carouselImage;
    @Version
    private Integer version;

}
